package cn.echoedu.control;

import java.util.List;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import cn.echoedu.command.base.SuccessParam;
import cn.echoedu.entity.SchoolCalendar;
import cn.echoedu.entity.TelContacts;
import cn.echoedu.entity.receivecommand.QueryContactsListReceive;
import cn.echoedu.entity.receivecommand.QuerySchoolCalendarReceive;

public class ContactsListControl extends BaseControl{

	public void doQueryContactsList(HttpServletRequest request,
			HttpServletResponse response,
			QueryContactsListReceive queryContactsListreceive) {
		
		List<TelContacts> schoolCalendarlist = getContactsListModel().queryContactsList(
				queryContactsListreceive.getSchoolcode(),queryContactsListreceive.getSearch_key());
		System.out.println("-------->"+schoolCalendarlist.toString());
		sendSuccess(getSuccessParam2(request, response,schoolCalendarlist,
				queryContactsListreceive.getCode()));
		
	}
	
	private void sendSuccess(SuccessParam successparam){
		getResponseService().doQueryContactsListSuccess(successparam);
	}
	

}
